package com.example.demo.common.api;

import lombok.Data;
import lombok.Getter;

/**
 * @Author: csj
 * @Date: 2024/4/7 16:37
 * @Description:
 */
@Getter
public enum ResultCodeEnum {
    SUCCESS(1, "操作成功"),
    FAILED(10001, "接口错误"),
    VALIDATE_FAILED(10002, "参数校验失败"),
    ACCESS(403, "暂无权限"),
    ERROR(10003, "未知错误");

    private int code;
    private String msg;

    ResultCodeEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }
}
